<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/public/base.jspf"%>
<!DOCTYPE html>
<html>
<head>
	<title>商品品牌</title>
	<%@include file="/public/base_css.jspf"%>
	<%@include file="/public/base_js.jspf"%>
</head>
<body>
	<!-- 数据表格 -->
	<table id="datagrid_list"></table>
</body>
<script type="text/javascript">
	$('#datagrid_list').datagrid({
		url:'pageList',
        loadFilter:function(data){
        	return data.obj;
        },
        fitColumns:true,
        rownumbers:true,
	    singleSelect:true,
	    pagination:true,
	    fit:true,
        idField:'id',
        toolbar: [{
			iconCls: 'icon-add',
			text:'添加品牌',
			handler: function(){add();}
		},'-',{
			iconCls: 'icon-edit',
			text: '修改品牌',
			handler: function(){update();}
		},'-',{
			iconCls: 'icon-cancel',
			text: '删除',
			handler: function(){del();}
		}],
        columns:[[{
        	title:'品牌名称',
        	field:'text'
        },{
        	title:'品牌LOGO',
        	field:'logo'
        },{
        	title:'所属分类',
        	field:'goodsTypeText'
        },{
        	title:'创建时间',
        	field:'createTime'
        },{
        	title:'修改时间',
        	field:'editTime'
        }]]
	});

	function add(){
		createWindown('editPage/0','添加类型',320,310);
	}

	function update(){
		createUpdateWindown('datagrid_list','editPage','修改类型',320,310);
	}

	function del(){
		createDelDialog('datagrid_list','manage','删除','确认删除本条数据吗？');
	}
</script>
</html>